package com.llh.demo4devops.controller

import org.springframework.stereotype.Controller
import org.springframework.web.bind.annotation.GetMapping
import org.springframework.web.servlet.ModelAndView
import java.time.LocalDateTime

/**
 *
 * <p>Created At 2021/2/8 15:30
 * @author llh
 * @since 3.1
 */
@Controller
class HomeController {

    @GetMapping("home", "", "index")
    fun home(mv: ModelAndView): ModelAndView {

        mv.viewName = "home"
        mv.addObject("time", LocalDateTime.now())
        return mv
    }
}